package com.railway.dao.impl;

import java.util.List;

import org.springframework.jdbc.core.BeanPropertyRowMapper;
import org.springframework.jdbc.core.JdbcTemplate;

import com.railway.util.DBUtil;
import com.railway.bean.Images;
import com.railway.dao.ImagesDao;

public class ImagesDaoImpl implements ImagesDao{

	JdbcTemplate jt = new JdbcTemplate(DBUtil.getDataSource());
	@Override
	public List<Images> selectImage() {
		String sql = "select * from images";
		return jt.query(sql, new BeanPropertyRowMapper<Images>(Images.class));
	}

}
